import {addData, deleteById, listData, pageData, updateById} from "@/services/base-request";
import {ParamsType} from "@ant-design/pro-components";

export const pageVehicleAPI = (params: ParamsType) => {
  return pageData("/vehicle", params)
}
export const listVehicleAPI = (params: ParamsType) => {
  return listData("/vehicle", params)
}

export const addVehicleAPI = (data: API.IVehicle) => {
  return addData("/vehicle", data)
}

export const updateVehicleAPI = (data: API.IVehicle) => {
  return updateById("/vehicle", data)
}

export const deleteVehicleAPI = (id: string | number) => {
  return deleteById("/vehicle", id)
}
